package cn.bdqn.controller;

import cn.bdqn.model.DrugBatch;
import cn.bdqn.service.DrugBatchService;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * 药品批次表(DrugBatch)表控制层
 *
 * @author makejava
 * @since 2021-03-19 22:55:05
 */
@RestController
@RequestMapping("drugBatch")
public class DrugBatchController {
    /**
     * 服务对象
     */
    @Resource
    private DrugBatchService drugBatchService;

    /**
     * 通过主键查询单条数据
     *
     * @param id 主键
     * @return 单条数据
     */
    @GetMapping("selectOne")
    public DrugBatch selectOne(Long id) {
        return this.drugBatchService.queryById(id);
    }

}
